package com.smmisia.auth.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.smmisia.common.entity.auth.User;
import com.smmisia.common.request.auth.LoginRequest;
import com.smmisia.common.request.auth.UserRequest;
import com.smmisia.common.request.auth.UserUpdateRequest;
import com.smmisia.common.request.auth.CodeRequest;
import com.smmisia.common.request.auth.RegisterRequest;
import com.smmisia.common.Result.Result;
import com.smmisia.common.response.auth.CodeResponse;
import com.smmisia.common.response.auth.UserResponse;

import java.io.IOException;
import java.util.List;


public interface UserService extends IService<User> {

    Result<CodeResponse> code(CodeRequest request);

    Result<String> register(RegisterRequest request);

    Result<String> doLogin(LoginRequest loginRequest);

    Result<UserResponse> info();

    Result<List<UserResponse>> infoList(Integer pageNum, Integer pageSize);

    Result<String> status(Integer id);

    Result<String> updateUserInfo(UserRequest userRequest);

    Result<String> deleteUserInfo(Integer id);

    Result<String> search(String email);

    Result<String> updateUserInfos(UserUpdateRequest userDTO);

    User getUserById(Integer id);

    Result<String> jx(String url) throws IOException;
}
